# This file is part of BlackArch Linux ( https://www.blackarch.org/ ).
# See COPYING for license details.

pkgname=paraxor-dwm
pkgver=6.0
pkgrel=4
pkgdesc="Dynamic window manager for X (paraxor's fork)."
arch=('x86_64' 'aarch64')
url='http://dwm.suckless.org/'
license=('GPL')
depends=('xorg-server' 'xorg-xsetroot' 'libx11' 'libxinerama')
makedepends=('git')
conflicts=('dwm')
provides=('dwm')
source=("$pkgname::git+http://github.com/paraxor/dwm")
sha512sums=('SKIP')

prepare() {
  cd $pkgname

  sed -i 's/CPPFLAGS =/CPPFLAGS +=/g' config.mk
  sed -i 's/^CFLAGS = -g/#CFLAGS += -g/g' config.mk
  sed -i 's/^#CFLAGS = -std/CFLAGS += -std/g' config.mk
  sed -i 's/^LDFLAGS = -g/#LDFLAGS += -g/g' config.mk
  sed -i 's/^#LDFLAGS = -s/LDFLAGS += -s/g' config.mk
}

build() {
  cd $pkgname

  make X11INC=/usr/include/X11 X11LIB=/usr/lib/X11
}

package() {
  cd $pkgname

  make PREFIX=/usr DESTDIR="$pkgdir" install
}

